package com.suxin.netty.remoting;

import io.netty.channel.ChannelHandlerContext;

/**
 * @author Tang
 * @classname AsyncNettyRequestProcessor
 * @description [ 异步处理器 ]
 * @date 2022/12/14 22:54
 */
public abstract class AsyncNettyRequestProcessor implements NettyRequestProcessor{

    /**
     * 异步处理
     * @param ctx
     * @param rc
     * @param callback
     */
    public void AsyncProcessRequest(ChannelHandlerContext ctx, RemotingCommand rc,RemotingResponseCallback callback) {
        processRequest(ctx, rc);
        callback.callback(rc);
    }
}
